package com.iwuke.dance.util;

import android.os.Handler;
import android.os.Looper;
import android.widget.ImageView;
import android.widget.TextView;

/**
 * @author: 魏从响
 * @date: 2025/9/24
 */
public class ClickableUtil {

    /**
     * @description 设置点击间隔
     * @param
     * @return
     * @author 魏从响
     * @time 2025/9/24 16:19
     */
    public void isClickable(ImageView imageView) {
        imageView.setClickable(false);
        new Handler(Looper.getMainLooper()).postDelayed(new Runnable() {
            @Override
            public void run() {
                imageView.setClickable(true);
            }
        },1000);
    }

    public void isClickable(TextView textView) {
        textView.setClickable(false);
        new Handler(Looper.getMainLooper()).postDelayed(new Runnable() {
            @Override
            public void run() {
                textView.setClickable(true);
            }
        },1000);
    }

    //加载中
    public void setLoading(){

    }

}
